package com.atguigu.gulimall.cart.service;

import com.atguigu.gulimall.cart.vo.Cart;
import com.atguigu.gulimall.cart.vo.CartItem;

import java.util.List;
import java.util.concurrent.ExecutionException;

public interface CartService {
    CartItem addCart(Long skuId, Integer num) throws ExecutionException, InterruptedException;

    CartItem getCartItemBySkuId(String skuId);

    Cart getCart() throws ExecutionException, InterruptedException;
    void deleteCart(String cartKey);

    void checkItem(String skuId, Integer check);

    void countItem(String skuId, Integer num);

    void deleteItem(String skuId);

    List<CartItem> getCheckedCart();
}
